package com.eastfair.imaster.dao;

import com.eastfair.boot.mapper.SuperMapper;
import com.eastfair.imaster.entity.News;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

/**
 * <p>
 * Mapper 接口
 *
 * </p>
 *
 * @author zjn
 * @date 2021-08-31
 */
@Repository
public interface NewsMapper extends SuperMapper<News> {

    /**
     * 大于等于小序号且小于大序号 的值都+1
     *
     * @param projectId     项目id
     * @param smallSequence 小序号
     * @param bigSequence   大序号
     */
    void updateSequenceBetween(@Param("projectId") Long projectId, @Param("smallSequence") Integer smallSequence, @Param("bigSequence") Integer bigSequence);

}
